/***    
request.globalRequest(url,请求方式,obj数据,123,true单,true 多array)url, method, data, power, isUpload, isFiles
1===没登录前的请求头
2===携带请求头token
3===刷新token
***/
import request from '@/util/network_request/request.ts'
const apiNetwork = {}
// 创建服务商
apiNetwork.saveNetwork = (data, inviteCode) => request.globalRequest({
	url: `/mobile/network/saveNetwork/${inviteCode}`,
	method: 'POST',
	data,
	power: 2
})
// 根据邀请码获取企业信息
apiNetwork.getCustomerInfo = (inviteCode) => request.globalRequest({
	url: `/mobile/network/getCustomerInfo/${inviteCode}`,
	method: 'GET',
	power: 2
})
// 加入服务商
apiNetwork.joinNetwork = (data, inviteCode) => request.globalRequest({
	url: `/mobile/network/joinNetwork/${inviteCode}`,
	method: 'POST',
	data,
	power: 2
})
// 根据邀请码获取服务商信息
apiNetwork.getNetworkInfo = (inviteCode) => request.globalRequest({
	url: `/mobile/network/getNetworkInfo/${inviteCode}`,
	method: 'GET',
	power: 2
})
// 校验工程师加入服务商的邀请码
apiNetwork.checkJoinNetworkInviteCode = (inviteCode) => request.globalRequest({
	url: `/mobile/network/checkJoinNetworkInviteCode/${inviteCode}`,
	method: 'GET',
	power: 2
})
// 校验服务商加入企业的邀请码
apiNetwork.checkNetworkJoinCustomer = (inviteCode) => request.globalRequest({
	url: `/mobile/network/checkNetworkJoinCustomer/${inviteCode}`,
	method: 'GET',
	power: 2
})
//发送短信邀请码
apiNetwork.sendInviteCode = (data) => request.globalRequest({
	url: `/mobile/network/sendInviteCode`,
	method: 'GET',
	data,
	power: 2
})
//生成邀请码
apiNetwork.getInviteCode = () => request.globalRequest({
	url: `/mobile/network/getInviteCode`,
	method: 'GET',
	power: 2
})
// 获取工程师认证自定义字段
apiNetwork.getNetworkEmpAuthenField = () => request.globalRequest({
	url: `/mobile/select/getNetworkEmpAuthenField`,
	method: 'GET',
	power: 2
})
// 获取工程师自定义字段
apiNetwork.getNetworkEmpFields = () => request.globalRequest({
	url: `/mobile/select/getNetworkEmpFields`,
	method: 'GET',
	power: 2
})
// 获取待办数量
apiNetwork.getToDoQty = () => request.globalRequest({
	url: `/mobile/network/order/getToDoQty`,
	method: 'GET',
	power: 2
})
// 获取侧边栏数据
apiNetwork.getSidebarData = () => request.globalRequest({
	url: `/mobile/network/order/getSidebarData`,
	method: 'GET',
	power: 2
})
// 获取工单合计(首页-工单统计-工单合计)
apiNetwork.getNetworkOrderStat = (data) => request.globalRequest({
	url: `/mobile/network/order/getNetworkOrderStat`,
	method: 'post',
	data,
	power: 2
})
// 获取排行榜数据
apiNetwork.getNetworkOrderScoreStat = (data) => request.globalRequest({
	url: `/mobile/network/order/getNetworkOrderScoreStat`,
	method: 'post',
	data,
	power: 2
})
//获取工单报表(工单类型占比)
apiNetwork.getNetworkOrderModuleStat = (data) => request.globalRequest({
	url: `/mobile/network/order/getNetworkOrderModuleStat`,
	method: 'post',
	data,
	power: 2
})
// 获取工单报表(工单分析)
apiNetwork.getWeekOrderStat = () => request.globalRequest({
	url: `/mobile/network/order/getWeekOrderStat`,
	method: 'get',
	power: 2
})
//获取服务商移动端人员列表
apiNetwork.getNetworkMobileEmpList = (data) => request.globalRequest({
	url: `/mobile/network/getNetworkMobileEmpList`,
	method: 'post',
	data,
	power: 2
})
//获取服务商近七天的工单数
apiNetwork.getNetworkInSevenDaysOrder = () => request.globalRequest({
	url: `/mobile/network/order/getNetworkInSevenDaysOrder`,
	method: 'post',
	power: 2
})
//获取服务商个人仓列表
apiNetwork.getStoreList = (data) => request.globalRequest({
	url: `/mobile/network/store/getStoreList`,
	method: 'post',
	data,
	power: 2
})
// 获取服务商仓库商品明细列表
apiNetwork.getStoreGoodsList = (data, storeId) => request.globalRequest({
	url: `/mobile/network/store/getStoreGoodsList/${storeId}`,
	method: 'post',
	data,
	power: 2
})
//获取服务商团队模式
apiNetwork.getNetworkTeamType = () => request.globalRequest({
	url: `/mobile/network/getNetworkTeamType`,
	method: 'post',
	power: 2
})

// 获取是否允许超管代工程师提现
apiNetwork.getIsAllowManagerHelpWithdrawStrategy = () => request.globalRequest({
	url: '/mobile/network/getIsAllowManagerHelpWithdrawStrategy',
	method: 'get',
	power: 2
})

// 获取网点的操作权限
apiNetwork.getNetworkMobileOperateRoot = () => request.globalRequest({
	url: '/mobile/network/getNetworkMobileOperateRoot',
	method: 'get',
	power: 2
})

// 获取公告未读数量
apiNetwork.getMobileSysNoticeUnreadNum = (data) => request.globalRequest({
	url: '/mobile/network/getMobileSysNoticeUnreadNum',
	method: 'post',
	data,
	power: 2
})
export default apiNetwork